import { EntitySchema } from '@mikro-orm/core';

export class TableName {
  id!: number;
  createTime?: Date;
  name?: string;
}

export const TableNameSchema = new EntitySchema({
  class: TableName,
  properties: {
    id: { primary: true, type: 'number' },
    createTime: { type: 'Date', length: 0, nullable: true },
    name: { type: 'string', length: 255, nullable: true },
  },
});
